<template>
  <div class="product">
    <h3>{{ title }}</h3>
    <ul>
      <li v-for="item in goodList" :key="item.id">
        <img :src="item.list_pic_url" alt="" />
        <p>{{ item.name }}</p>
        <span>{{ item.retail_price | formatPrice }}</span>
      </li>
    </ul>
  </div>
</template>

<script>
export default {
  name: "fenlei",
  props: ["goodList", "title"],
  data() {
    return {};
  },
  mounted() {},
  methods: {},
};
</script>

<style lang='less' scoped>
.product {
  h3{
    text-align: center;
    height: 1.33333rem;
    line-height: 1.33333rem;
    font-size: 0.48rem;
  }
  ul{
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    padding: 0.26667rem;
    box-sizing: border-box;
    width: 100%;
    li{
      width: 49%;
      background: #fff;
      text-align: center;
      margin-bottom: 0.26667rem;
      padding-bottom: 0.26667rem;
      img{
        width: 100%;
      }
      p{
        background: #fff;
        text-align: center;
        margin-bottom: 0.26667rem;
        padding-bottom: 0.26667rem;
        font-size: 0.42667rem;
      }
      span{
        margin-top: 0.13333rem;
        color: darkred;
        font-size: 0.42667rem;
      }
    }

  }
}

 
</style>
